package answers;

public class ShortAnswer implements IAnswer
{
	public ShortAnswer(String text)
	{
		this.text = text;
	}

	@Override
	public boolean compare(IAnswer other)
	{
		if((other instanceof ShortAnswer) == false)
		{
			return false;
		}
		else if(((ShortAnswer)other).getText().equals(this.text))
		{
			return true;
		}
		else
		{
			return false;
		}
	}

	@Override
	public String getText()
	{
		return text;
	}

	private String text;
}
